NumberOfCopies Method

Wintellect PowerCollections

Collapse imageExpand ImageCollapseAll imageExpandAll imageDropDown imageDropDownHover imageCopy imageCopyHover image
[This topic is pre-release documentation and is subject to change in future releases. Blank topics are included as placeholders.]

Returns the number of copies of item in the bag. More precisely, returns the number of items in the bag that compare equal to item.

Namespace: Wintellect.PowerCollections
Assembly:  PowerCollections (in PowerCollections.dll)

Syntax

C#
public int NumberOfCopies(
	T item
)
Visual Basic (Declaration)
Public Function NumberOfCopies ( _
	item As T _
) As Integer
Visual C++
public:
int NumberOfCopies (
	T item
)

Parameters

item
T
The item to search for in the bag.

Return Value

The number of items in the bag that compare equal to item.

Remarks

NumberOfCopies() takes time O(log N + M), where N is the total number of items in the bag, and M is the number of copies of item in the bag.

See Also